<template>
	<view>
		<h1 style="margin-top:30px">新华学生(教职工)信息登入申请</h1>
		<img src="../../static/logo (2).png" alt="" />
		<h3>非本院人员请勿申请注册</h3>
		<view class="zhu_con">
			<view class="zhu_con_view">
				请输入您的姓名
				<input type="text" value="" />
			</view>
			<view class="zhu_con_view sex">
				<radio-group name="">
					性别：
					<label>
						<radio v-model="sex" value="男" /><text>男</text>
					</label>
					<label>
						<radio v-model="sex" value="女" /><text>女</text>
					</label>
				</radio-group>

			</view>
			<view class="zhu_con_view ">
				<radio-group name="">
					身份：
					<label>
						<radio v-model="shen" value="教师" @click="shen = ''" /><text>教师</text>
					</label>
					<label>
						<radio v-model="shen" value="学生" @click="shen = '学生'" /><text>学生</text>
					</label>
				</radio-group>
			</view>
			<view class="zhu_con_view" v-show="shen == '学生'">
				班主任姓名：
				<input type="text" value="" />
			</view>
			<view class="zhu_con_view">
				所学专业：
				<picker @change="bindPickerChange" :value="index" :range="array">
					<view class="uni-input">{{array[index]}}</view>
				</picker>
			</view>
			<view class="zhu_con_view">
				邮箱：
				<input type="email" v-model="email" value="" />
			</view>
			<view class="warning zhu_con_view" v-show="warning">
				请不要留空
			</view>
			<view class="zhu_con_view">
				<button type="primary" @click="send">点击提交</button>
				<button type="default" @click="goBack">取消x</button>
			</view>
			
		</view>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				sex: "",
				shen: "",
				ban:"",
				index: 0,
				array: ["点击选择", "软件开发","ui设计","vr","网传"],
				email:"",
				warning:false
			}
		},
		methods: {
			bindPickerChange: function(e) {
				
				this.index = e.target.value
			},
			send(){
				uni.showToast({
				    title: '提交成功,等待审核',
				    duration: 2000
				});
			},
			goBack(){
				uni.navigateTo({
				    url: '/pages/login/login'
				});
			}
		}
	}
</script>

<style>
	.zhu_con_view {
		margin-top: 20rpx;
	}

	page {
		text-align: center;
	}

	h1:nth-child(1) {
		font-size: 50rpx;
	}

	img {
		margin: 0 auto;
		max-height: 120rpx;
	}

	.zhu_con {
		text-align: left;
		padding: 0 30rpx;
		margin-top: 42rpx;
	}
	.warning{
		color: #f56c6c;
	}
	input {
		border-bottom: 1px solid #007AFF;
	}
</style>
